<p class="Paragraph">Year: Integer expression that indicates the year. All values between 0 and 99 are interpreted as the years 1900?1999. For other year arguments, you must enter all four digits.</p>
<p class="Paragraph">Month: Integer expression that indicates the month of the specified year. The accepted range is between 1 and 12.</p>
<p class="Paragraph">Day: Integer expression that indicates the day of the specified month. The accepted range is between 1 and 28, 29, 30 or 31 (depending on the number of days in the given month).</p>
<p class="Paragraph">The <span class="T1">DateSerial function</span> returns the number of days between December 30,1899 and the given date. You can use this function to calculate the difference between two dates.</p>
<p class="Paragraph">The function returns the data type Variant with VarType 7 (Date); internally, this value is stored as a Double value. Thus, 1.1.1900 results in the value 2. Negative values correspond to dates before December 30, 1899 (not inclusive).</p>
<p class="Paragraph">If a date is defined which lies outside of the accepted range, <help:productname xmlns:help="http://openoffice.org/2000/help">%PRODUCTNAME</help:productname> Basic returns an error message.</p>
<p class="Paragraph">The difference to the <span class="T1">DateValue function</span> is that there you define the function argument as a string which contains the date. In contrast, the <span class="T1">DateSerial function</span> evaluates each of the parameters (year, month, day) as separate numeric expressions.</p>